import React from "react";
import { DatePicker } from 'antd';
import dayjs from "dayjs";
import moment from "moment";
const dateFormat = 'YYYY-MM-DD';



const Zcdatepicker = (props) => {
    const { picker, format = "YYYY-MM-DD" } = props

    const onChange = (date, dateString) => {
        console.log(date, dateString);
    };

    return (
        <>
            <DatePicker
                onChange={onChange}
                picker={picker ? picker : null}
                format={format}
                style={{
                    width: "100%"
                }}
                defaultValue={dayjs()}
                {...props}


            />
        </>
    )
}

export default Zcdatepicker